package com.songcha.sakura.ui.adapter

import android.content.Context


import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.viewholder.BaseViewHolder
import com.songcha.library_common.ui.view.CustomButton
import com.songcha.sakura.R
import com.songcha.sakura.bean.ComicDetailBean


class ComicEpisodeAdapter(val mContext: Context, resId:Int, list:MutableList<ComicDetailBean.EpisodeBean>) : BaseQuickAdapter<ComicDetailBean.EpisodeBean,BaseViewHolder>(resId,list) {

    init {
        addChildClickViewIds(R.id.cbtn_episode)
    }

    //private var mAddToCartListener:I_AddToCart?=null

     /*fun setOnAddToCartListener(listener:I_AddToCart){
        mAddToCartListener=listener
    }*/


    override fun convert(holder: BaseViewHolder, item: ComicDetailBean.EpisodeBean) {

        holder.getView<CustomButton>(R.id.cbtn_episode).text=item.episode

    }

}